<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
	<head>
		<title>SWFObject 2 dynamic publishing example page</title>
		<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
		<script type="text/javascript" src="./js/swfobject.js"></script>
        <script type="text/javascript" src="./js/swfmacmousewheel2.js"></script>
		<script type="text/javascript" src="./js/swfaddress.js"></script>
		
		
		
		<script type="text/javascript"> 
		
		
			function getViewportSize() { 
				var size = [0, 0]; 
				if (typeof window.innerWidth != "undefined") { 
					size = [window.innerWidth, window.innerHeight];
				} 
				else if (typeof document.documentElement != "undefined" && typeof document.documentElement.clientWidth != "undefined" && document.documentElement.clientWidth != 0) {
					size = [document.documentElement.clientWidth, document.documentElement.clientHeight]; 
				}
				else {
					size = [document.getElementsByTagName("body")[0].clientWidth, document.getElementsByTagName("body")[0].clientHeight]; 
				}
				return size; 
			}
			
			function createFullBrowserFlash() {
			
				swfobject.createCSS("html", "margin:0;height:100%;");
				swfobject.createCSS("body", "margin:0;height:100%;");
				swfobject.createCSS("#swf_content", "margin:0; width:100%; height:100%; min-width:770px; min-height:390px;display:block");
				
				window.onresize = function() {
					var el = document.getElementById("swf_content");
					var size = getViewportSize(); 
	 				el.style.width = size[0] < 770 ? "770px" : "100%";
					el.style.height = size[1] < 390 ? "390px" : "100%";
				};
				
				window.onresize();
				
			}
			
			
			
			
			var flashvars = {};
			flashvars.confFile = "datas/conf.xml";
			
			var params = {};
			params.allowscriptaccess = "always";
			
			var attributes = {};
			
			swfobject.embedSWF("swf/main.swf", "swf_content", "100%", "100%", "10", "expressInstall.swf", flashvars, params, attributes);
			
			if( swfobject.ua.mac )
				swfmacmousewheel.registerObject("swf_content");
			
			
			if (swfobject.hasFlashPlayerVersion("6.0.0")) {
				swfobject.addDomLoadEvent( createFullBrowserFlash );
			}
			
			
		</script> 
		
		
		
	</head>
	
	<body>
		<div id="swf_content" >
			<h1>Alternative content</h1>
			<p><a href="http://www.adobe.com/go/getflashplayer"><img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash player" /></a></p>
		</div>
	</body>
</html>
